package com.wlc.base.array;

/**
 * @author 王立朝 wanglichao@champion-credit.com
 * @description 多维数组
 * @date 2021-06-24 13:50
 */
public class ArrayDemo03 {
    /**
     * 多维数组的理解
     * array[0]   1,2
     * array[1]   3,4
     * array[2]   5,6
     * array[3]   7,8
     */
    public void method01(){
        int[][] numbers = {{1,2},{3,4},{5,6},{7,8}};
        System.out.println(numbers[1][0]);
        System.out.println("==========");
        for (int i = 0; i < numbers.length; i++) {
            for (int j = 0; j < numbers[i].length; j++) {
                System.out.print(numbers[i][j]+" ");
            }
            System.out.println();
        }
    }
    public static void main(String[] args) {
        new ArrayDemo03().method01();
    }
}
